<%--
  Created by IntelliJ IDEA.
  User: 61741
  Date: 2018/1/21
  Time: 19:39
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<script type="text/html" id="carouselTmpl">
    <tr>
        <td>
            <img data-src="\${thumb_url}" onerror="this.src='\${ctx}/resources/ueditor/dialogs/image/images/image.png'"
                 style="width:12rem;max-height:8rem;"/>
        </td>
        <td>
            <p><code>开始时间</code> \${formatDate(startTime)}</p>
            <p><code>结束时间</code> \${formatDate(endTime)}</p>
        </td>
        <td>
            <div>
                <span>\${type_desc}</span>
                {{if type == "LINK"}}
                <a href="\${value}">\${value}</a>
                {{else}}
                <div class="target-value" data-value="\${value}" data-type="\${type}">
                    <i class="fa fa-spin fa-spinner"></i>Loading
                </div>
                {{/if}}
            </div>
        </td>
        <td>
            <label>\${city_desc}</label>
        </td>
        <td>
            <button class="btn btn-danger" onclick="delCarousel('\${cid}')">删除</button>
        </td>
    </tr>
</script>

<script type="text/html" id="goodItemTmpl">
    {{each(i,fg) flags}}
    {{if fg.name == target }}
    <%--<div class="good-item" data-id="\${good_id}" title="\${goodName}|点击删除" data-city="\${fg.city}"--%>
         <%--onclick="delGood('\${good_id}','DELETE',this);">--%>
        <%--<img src="\${img[0]}" />--%>
        <%--<p><em>\${goodName}</em></p>--%>
        <%--&lt;%&ndash;<code>&ndash;%&gt;--%>
        <%--&lt;%&ndash;\${fg.city_desc}&ndash;%&gt;--%>
        <%--&lt;%&ndash;</code>&ndash;%&gt;--%>

    <%--</div>--%>
    <span class="article-item" data-id="\${good_id}" data-city="\${fg.city}">
        <span class="item-title">\${goodName}</span>
                 <img src="\${img[0]}"/>

        <%--<span></span>--%>
        <i class="fa fa-trash-o" title="点击删除" onclick="delGood('\${good_id}','DELETE',this);"></i>
    </span>
    {{/if}}
    {{/each}}
</script>

<script type="text/html" id="shopItemTmpl">
    <span class="article-item" data-id="\${_id}">
        <span class="item-title">\${companyName}</span>
                 <img src="\${userLogo}"/>

        <%--<span></span>--%>
        <i class="fa fa-trash-o" title="点击删除" onclick="flagShop('DELETE','\${_id}','PORTAL');"></i>
    </span>
</script>
<script type="text/html" id="sellerTmpl">
    <span class="article-item" data-id="\${_id}">
        <span class="item-title">\${companyName}</span>
                 <img src="\${userLogo}"/>

        <%--<span></span>--%>
        <i class="fa fa-trash-o" title="点击删除" onclick="flagShop('DELETE','\${_id}','PORTAL_SELLER');"></i>
    </span>
</script>
<script type="text/html" id="agencyTmpl">
    <span class="article-item" data-id="\${_id}">
        <span class="item-title">\${companyName}</span>
                 <img src="\${userLogo}"/>

        <%--<span></span>--%>
        <i class="fa fa-trash-o" title="点击删除" onclick="flagShop('DELETE','\${_id}','PORTAL_AGENCY');"></i>
    </span>
</script>
<script type="text/html" id="partsTmpl">
    <span class="article-item" data-id="\${_id}">
        <span class="item-title">\${companyName}</span>
                 <img src="\${userLogo}"/>

        <%--<span></span>--%>
        <i class="fa fa-trash-o" title="点击删除" onclick="flagShop('DELETE','\${_id}','PORTAL_PARTS');"></i>
    </span>
</script>
<script type="text/html" id="logisticsTmpl">
    <span class="article-item" data-id="\${_id}">
        <span class="item-title">\${companyName}</span>
                 <img src="\${userLogo}"/>

        <%--<span></span>--%>
        <i class="fa fa-trash-o" title="点击删除" onclick="flagShop('DELETE','\${_id}','PORTAL_LOGISTICS');"></i>
    </span>
</script>
<script type="text/html" id="advieShopTmpl">
    {{each(index,flag) flags}}
    {{if flag.name=="ADVICE_SHOP"}}
    <span class="article-item" data-id="\${_id}" data-city="\${flag.city}">
        <span class="item-title">\${companyName}</span>
                 <img src="\${userLogo}"/>

        <%--<span></span>--%>
        <i class="fa fa-trash-o" title="点击删除" onclick="flagShop('DELETE','\${_id}','ADVICE_SHOP');"></i>
    </span>
    {{/if}}
    {{/each}}
</script>
<script type="text/html" id="articleItemTmpl">
    {{each(index,flag) flags}}
    <div class="article-item" data-id="\${id}" data-city="\${flag.city}">
        <div class="item-thumb">
            <img src="\${flag.img}"/>
        </div>
        <span class="item-title">\${main_title}</span>
        <%--<span class="item-city">\${flag.city_desc}</span>--%>
        <i class="fa fa-trash-o" onclick="doFlagArticle('DELETE','\${id}','\${flag.city}','\${flag.name}')"
           title="点击删除"></i>
    </div>
    {{/each}}
</script>
<script type="text/html" id="discountGoodTmpl">
    <span class="article-item">
        <img src="\${img[0]}"/>
         <span class="item-title">\${goodName}</span>
        <%--<span></span>--%>
        <i class="fa fa-trash-o" title="点击删除" onclick="flagGood('DELETE','\${good_id}','NEW_GOOD');"></i>
    </span>
</script>
